package pl.frasunek.s2933.jps.datastore;


public class IOIDProduce {
    private Class<? extends IOIDGen> ioidGeneratorClass;

    public IOIDProduce(Class<? extends IOIDGen> ioidGeneratorClass) {
        this.ioidGeneratorClass = ioidGeneratorClass;
    }

    public final IOIDGen getIOIDGenerator() {

        try {
            return ioidGeneratorClass.newInstance();
        } catch (InstantiationException e) {
            e.printStackTrace();
        } catch (IllegalAccessException e) {
            e.printStackTrace();
        }
        return null;
    }
}
